import { AlgoTypeEnum } from "@/constants/other-keys"

export interface AlgoBaseInfo {
  al_model_id: string | undefined
  /** 算法模型名称 */
  al_model_name: string
  /** 算法模型类型 */
  al_model_type?: AlgoTypeEnum
  /** 算法模型描述 */
  al_model_describe: string
  /** 算法模型文件路径 */
  al_model_path: string
  /** 算法模型标签 */
  al_model_tag: string
}

export interface AlgoViewInfo extends AlgoBaseInfo {
  al_model_id: string
}

export interface TableRequestData {
  /** 算法模型名称 */
  al_model_name?: string
  al_model_type: AlgoTypeEnum
  /** 发布时间 */
  publish_time?: string
  /** 截至时间 */
  end_time?: string
}

export interface PageTableRequestData extends TableRequestData {
  /** 当前页码 */
  current_page: number
  /** 查询条数 */
  size?: number
}

export interface TableData {
  create_user: {
    user_id: string
    user_name: string
    user_position: string
  }
  create_time: string
}

export interface AlgoTableData extends AlgoViewInfo, TableData {}
export type SearchAlgoTableResponseData = ApiResponseData<{
  total_pages: number
  total_count: number
  page_info: AlgoTableData[]
}>
export type AlgoInfoResponseData = ApiResponseData<AlgoBaseInfo>
export type AlgoListResponseData = ApiResponseData<AlgoTableData[]>
